package com.global.gbinventory.barang.model;

public class Gudang {
	
	private int id;
	private String kode;
	private String nama;
	private String lokasi;

	public Gudang(int id, String kode, String nama, String lokasi){
		this.id = id;
		this.kode = kode;
		this.nama = nama;
		this.lokasi = lokasi;
	}
	
	public int getId(){
		return this.id;
	}
	
	public void setId(int id){
		this.id = id;
	}
	
	public String getKode() {
		return kode;
	}

	public void setKode(String kode) {
		this.kode = kode;
	}

	public String getNama() {
		return nama;
	}

	public void setNama(String nama) {
		this.nama = nama;
	}

	public String getLokasi() {
		return lokasi;
	}

	public void setLokasi(String lokasi) {
		this.lokasi = lokasi;
	}
	
	@Override
	public boolean equals(Object obj) {
		if(obj instanceof Gudang){
			return ((Gudang) obj).getKode().equals(this.kode);
		}
		return false;
	}

}
